<!DOCTYPE html>
<html>

	<head>
		<meta charset="UTF-8">
		<title>综合分析</title>
		<link rel="stylesheet" href="css/bootstrap.css" />
		<link rel="stylesheet" href="css/statistics.css">
		<link rel="stylesheet" href="css/bootstrap-datepicker.standalone.css" />
		<!--<meta name="viewport" content="width=device-width, initial-scale=1">-->
		<script src="js/jquery-3.1.1.min.js"></script>
		<script src="js/bootstrap.min.js"></script>
		<script src="js/highcharts.js"></script>
		<script src="js/highcharts-more.js"></script>
		<script src="js/data.js"></script>
		<script src="js/bootstrap-datepicker.min.js"></script>
		<script src="locales/bootstrap-datepicker.zh-CN.min.js"></script>

		<script type="text/javascript">
			function showMessage(content) {
				var jsonString = '{"name":"xubohao","age":"24","sex":"man"}';
				var obj = JSON.parse(jsonString);
				document.getElementById("myFirstJavaToJs").innerHTML = content + obj.name;

			}

			function sendMessage() {
				document.location = "js://baidu123?type=123";
			}
		</script>
	</head>

	<!--	<body onload="javascript:contact.showM()">-->

	<body onload="sendMessage()">
		<div>
			<nav class="navbar navbar-default" role="navigation">
				<div class="container-fluid">
					<!-- Brand and toggle get grouped for better mobile display -->
					<div class="navbar-header">
						<button type="button" class="navbar-toggle collapsed" data-toggle="collapse" data-target="#bs-example-navbar-collapse-1">
                    <span class="sr-only">Toggle navigation</span>
                    <span class="icon-bar"></span>
                    <span class="icon-bar"></span>
                    <span class="icon-bar"></span>
                	</button>
						<a class="navbar-brand" href="#">报表</a>
					</div>

					<!-- Collect the nav links, forms, and other content for toggling -->
					<div class="collapse navbar-collapse" id="bs-example-navbar-collapse-1">
						<!--<ul class="nav navbar-nav">-->
							<form class="navbar-form navbar-left" method="get" action="js://nimei.com">
								<div class="input-group date" id="timepicker1">
									<input type="text" name="startTime" class="form-control" placeholder="点击选择对比开始时间">
									<span class="input-group-btn">
        								<button class="btn btn-default" type="button">
        									<i class="glyphicon glyphicon-time"></i>
        								</button>
      								</span>

								</div>

								<script>
									$('#timepicker1').datepicker({
										todayBtn: true,
										todayHighlight: true,
										autoclose: true,
										language: "zh-CN"
									});
								</script>

								<div class="input-group date" id="timepicker2">
									<input type="text" name="endTime" class="form-control" placeholder="点击选择对比开始时间">
									<span class="input-group-btn">
        								<button class="btn btn-default" type="button">
        									<i class="glyphicon glyphicon-time"></i>
        								</button>
      								</span>
								</div>

								<script>
									$('#timepicker2').datepicker({
										todayBtn: true,
										todayHighlight: true,
										autoclose: true,
										language: "zh-CN"
									});
								</script>

								<button class="btn btn-primary btn-block " type="submit" data-toggle="collapse" data-target = "#bs-example-navbar-collapse-1">确定</button>
							</form>
					</div>
				</div>
			</nav>

			<!--<div class="jumbotron">
        <p>集散中心第一季度报表</p>
    </div>-->
			<div class="panel panel-default">
				<div class="panel-body">
					<div class="statistics-title">总收入:</div>
					<div class="statistics-second">总支出:</div>
					<div id="myFirstJavaToJs"></div>
				</div>
			</div>

			<div id="container" style="height: 80%">
				<script language="JavaScript">
					//					$(window).resize(function() {
					//						chart.setSize(
					//							$(document).width(),
					//							$(document).height() / 1.5,
					//							false
					//						);
					//					});
					$(document).ready(function() {

						var chart = new Highcharts.Chart({

							chart: {
								type: 'column',
								renderTo: container,
								spacingTop: 3,
								spacingRight: 0,
								spacingBottom: 3,
								spacingLeft: 0
							},
							yAxis: {
								title: {
									text: ''
								}
							},
							xAxis: {
								categories: [
									'集散中心',
									'拉萨公交',
									'旅游包车',
									'出租车',
									'安全'
								]
							},
							yAxis: [{
								min: 0,
								title: {
									text: ''
								}
							}, {
								title: {
									text: ''
								},
								opposite: true
							}],
							legend: {
								shadow: false
							},
							tooltip: {
								shared: true
							},
							plotOptions: {
								column: {
									grouping: false,
									shadow: false,
									borderWidth: 0
								}
							},
							title: {
								text: '集散中心第一季度报表'
							},

							credits: {
								enabled: false
							},

							//							data: {
							//								columns: [
							//									[null, '1月', '2月', '3月', '4月', '5月', '6月', '7月', '8月', '9月', '10月'], // categories
							//									['收入', 5090, 6000, 8000, 6874, 4000, 5232.1, 4232.1, 7232.1, 5232.1, 5232.1], // first series
							//									['支出', 2258, 4200, 6000, 4232.21, 3000, 4254, 3254, 6254, 3254, 4254] // second series
							//								]
							//							}
							series: [{
								name: '收入1',
								color: 'rgba(165,170,217,1)',
								data: [150, 73, 20, 30, 40],
								tooltip: {
									valuePrefix: '￥',
									valueSuffix: ' 元'
								},
								pointPadding: 0.3,
								pointPlacement: -0.3
							}, {
								name: '收入2',
								color: 'rgba(126,86,134,.9)',
								data: [140, 90, 40, 90, 100],
								tooltip: {
									valuePrefix: '￥',
									valueSuffix: ' 元'
								},
								pointPadding: 0.4,
								pointPlacement: -0.3
							}, {
								name: '支出1',
								color: 'rgba(165,170,217,1)',
								data: [150, 73, 20, 30, 40],
								pointPadding: 0.3,
								tooltip: {
									valuePrefix: '￥',
									valueSuffix: ' 元'
								},
								pointPlacement: 0
							}, {
								name: '支出2',
								color: 'rgba(126,86,134,.9)',
								data: [140, 90, 40, 90, 100],
								tooltip: {
									valuePrefix: '￥',
									valueSuffix: ' 元'
								},
								pointPadding: 0.4,
								pointPlacement: 0
							}, {
								name: '盈余1',
								color: 'rgba(165,170,217,1)',
								data: [150, 73, 20, 30, 40],
								pointPadding: 0.3,
								tooltip: {
									valuePrefix: '￥',
									valueSuffix: ' 元'
								},
								pointPlacement: 0.3
							}, {
								name: '盈余2',
								color: 'rgba(126,86,134,.9)',
								data: [140, 90, 40, 90, 100],
								tooltip: {
									valuePrefix: '￥',
									valueSuffix: ' 元'
								},
								pointPadding: 0.4,
								pointPlacement: 0.3
							}]
						});
					});
				</script>
			</div>

		</div>

	</body>

</html>